<?php
session_start();
unset($_SESSION);
session_destroy();
if($_GET["action"]=="shutdown")
	{
	$server_status=`sudo /sbin/shutdown -h now`;
	exec ('sudo /sbin/shutdown -h now');
	?>
	<script language="JavaScript">
	alert("Server is shutting Down");
	window.close();
	</script>
	<?php
	}
else
	{
	$msg=("Logged Out");
	$msg=urlencode("$msg");
	header("Location:../index.php?msg=$msg");
	}
?>
